<template>
	<div class="navBox" >
		<div class="navTitle">{{title}}</div>
		<div class="navMore" @click="goPath">
			<div v-if="normal">
				<span>查看更多</span>
				<van-icon name="arrow" color="#323232"/>
			</div>
			<slot name="right"></slot>
		</div>
	</div>
</template>

<script>
	export default {
		props: {
			title: String,
			path: String,
			normal: {
				type: Boolean,
				default: true
			}
		},
		name: "navTitle",
		methods: {
			goPath() {
				this.$router.push({
					path: this.path
				})
			}
		}
	}
</script>

<style scoped lang="scss">
	.navBox {
		display: flex;
		align-items: center;
		justify-content: space-between;
		padding-right: 20px;

		.navTitle {
			font-size: 32px;
			color: #323232;
			font-weight: bold;
			padding: 0 18px;
			border-left: 6px solid $baseColor;
		}

		.navMore {
			font-size: 26px;
			color: #323232;
		}
	}
</style>
